﻿namespace ScreenWarnning
{
    public partial class FormHost : Form
    {
        public FormHost()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            if (string.IsNullOrWhiteSpace(txtHost.Text))
            {
                MessageBox.Show("请输入服务器地址");
                return;
            }

            GlobalContext.ServerHost = txtHost.Text;
            GlobalContext.DataProvider = new DataProvider(txtHost.Text);
            new FormLogin().Show();
            this.Hide();
        }
    }
}
